package day20.String;

import java.util.Scanner;

public class login {
    public static void main(String[] args) {

        String passUsername = "admin";
        String passPassword = "briup";

        Scanner scanner = new Scanner(System.in);

        System.out.print("请输入用户名：");
        String username = scanner.nextLine();

        System.out.println();
        
        System.out.print("请输入密码：");
        String password = scanner.nextLine();

        System.out.println();

        if (username.equals(passUsername) && password.equals(passPassword)) {
            System.out.println("登录成功");
        } else {
            System.out.println("登录失败，用户名或密码有误！");
        }
        
        scanner.close();
    }
}